using System;

namespace Entity.Hibernate
{
    public class SearchObj
    {
        public const String LG_AND = "AND";
        public const String LG_DEFAULT = "AND";
        public const String LG_IS_NOT_NULL = "isNotNull";
        public const String LG_IS_NULL = "isNull";
        public const String LG_OR = "OR";
        public const String OP_DEFAULT = "EQ";
        public const String OP_EQ = "EQ";
        public const String OP_GE = "GE";
        public const String OP_GT = "GT";
        public const String OP_LE = "LE";
        public const String OP_LIKE = "LIKE";
        public const String OP_LT = "LT";
        public const String OP_NE = "NE";

        public SearchObj(string _name, Object _value)
        {
            Name = _name;
            Value = _value;
            Oper = OP_DEFAULT;
            LogicOper = LG_DEFAULT;
        }

        public SearchObj(string _name, Object _value, string _oper, string _logicOper)
        {
            Name = _name;
            Value = _value;
            Oper = _oper;
            LogicOper = _logicOper;
        }

        public string Name { get; set; }

        public Object Value { get; set; }

        public string Oper { get; set; }

        public string LogicOper { get; set; }
    }
}